package treeNode

import "fmt"

type TreeNode struct {
	Value               int
	LeftNode, RightNode *TreeNode
}

func (t *TreeNode) String() string {
	if t == nil {
		return ""
	}
	// return fmt.Sprintf("value:%d, LeftNode:{%s}, RightNode:{%s}", t.Value, t.LeftNode.String(), t.RightNode.String())
	return fmt.Sprintf("%d, %s, %s", t.Value, t.LeftNode.String(), t.RightNode.String())
}
